package com.ruoyi.system.domain;

import java.math.BigDecimal;
import java.util.Date;

import com.baomidou.mybatisplus.annotation.TableLogic;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.MPBaseEntity;

/**
 * 产品对象 product
 *
 * @author 萧萧
 * @date 2021-09-25
 */
public class Product extends MPBaseEntity {
    private static final long serialVersionUID = 1L;

    /**
     *
     */
    private Integer id;

    /**
     * 1正常，0删除
     */
    @TableLogic
    private Integer flag;

    /**
     * 上级分裂ID，默认是0
     */
    @Excel(name = "上级分裂ID，默认是0" )
    private Long productId;

    /**
     * 产品名称
     */
    @Excel(name = "产品名称" )
    private String name;

    /**
     * 本期目标
     */
    @Excel(name = "本期目标" )
    private BigDecimal startAmount;

    /**
     * 投资币种(默认USDT)
     */
    @Excel(name = "投资币种(默认USDT)" )
    private String coinName;

    /**
     * 初始抢购时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd" )
    @Excel(name = "初始抢购时间" , width = 30, dateFormat = "yyyy-MM-dd" )
    private Date panicTime;

    /**
     * 出局奖励（默认百分之12）
     */
    @Excel(name = "出局奖励" , readConverterExp = "默=认百分之12" )
    private BigDecimal award;

    public void setId(Integer id) {
        this.id = id;
    }

    public Integer getId() {
        return id;
    }

    public void setFlag(Integer flag) {
        this.flag = flag;
    }

    public Integer getFlag() {
        return flag;
    }

    public void setProductId(Long productId) {
        this.productId = productId;
    }

    public Long getProductId() {
        return productId;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getName() {
        return name;
    }

    public void setStartAmount(BigDecimal startAmount) {
        this.startAmount = startAmount;
    }

    public BigDecimal getStartAmount() {
        return startAmount;
    }

    public void setCoinName(String coinName) {
        this.coinName = coinName;
    }

    public String getCoinName() {
        return coinName;
    }

    public void setPanicTime(Date panicTime) {
        this.panicTime = panicTime;
    }

    public Date getPanicTime() {
        return panicTime;
    }

    public void setAward(BigDecimal award) {
        this.award = award;
    }

    public BigDecimal getAward() {
        return award;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
                .append("id" , getId())
                .append("createTime" , getCreateTime())
                .append("updateTime" , getUpdateTime())
                .append("flag" , getFlag())
                .append("productId" , getProductId())
                .append("name" , getName())
                .append("startAmount" , getStartAmount())
                .append("coinName" , getCoinName())
                .append("panicTime" , getPanicTime())
                .append("award" , getAward())
                .toString();
    }
}
